<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <title>Document</title>
    <link rel="stylesheet" href="../css/news.css">
    <link rel="stylesheet" href="../css/footer.css">
    <style>
        .se1{
            padding: 5px 17px 17px 17px;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .type{
            margin-right: 38px;
            font-size: 17px;
            color: #666666;
        }
        .on{
            font-size: 18px;
            color: #333333;
        }
        .search{
            width: 20px;

            /*margin-right: 25px;*/
        }
        .met{
            display: flex;
            align-items: center;
        }
        .se2{
            padding: 0 17px;
        }
        .lei{
            color: #999;
            font-size: 13px;
            margin-right: 35px;
        }
        .se2 .active{
            font-size: 12px;
            background-color: #ead4fc;
            border-radius: 100px;
            padding: 1px 6px;
        }
    </style>
</head>

<body>
    <div id="view" v-cloak>
        <header>
            <div class="se1">
                <div class="tabss">
                    <span class="type" :class="{on: act < 4}" onclick="randomSwitchBtn(0, 'one2')">推荐</span>
                    <span class="type" :class="{on: act > 3}" onclick="randomSwitchBtn(4, 'one2')">交友</span>
                </div>
                <div class="met">
                    <img src="../image/index_images/filter.png" class="search" onclick="_url({}, 'frame0/search_case')"/>
                    <span>筛选</span>

                    <!-- <img src="../image/zhibo/zuan.png" class="zuan" onclick="_url({url:'zhibo/huiyuan', title:'皇冠会员'})"/> -->

                </div>
            </div>
            <div class="se2" v-if="act < 4">
                <span class="lei" :class="{active: act === 0}" onclick="randomSwitchBtn(0, 'one2')">热门</span>
                <span class="lei" :class="{active: act === 1}" onclick="randomSwitchBtn(1, 'one2')">最新</span>
                <span class="lei" :class="{active: act === 2}" onclick="randomSwitchBtn(2, 'one2')">关注</span>
                <span class="lei" :class="{active: act === 3}" onclick="randomSwitchBtn(3, 'one2')">附近</span>
            </div>
            <div class="se2" v-else>
                <span class="lei" :class="{active: act === 4}" onclick="randomSwitchBtn(4, 'one2')">推荐</span>
                <span class="lei" :class="{active: act === 5}" onclick="randomSwitchBtn(5, 'one2')">附近</span>
            </div>

        </header>
        <!-- 脚部 -->
        <footer>
            <ul class="f-wrap flex-c">
                <li class="f-list active">
                    <img src="../image/tabbar/yuanfen_sel.png" alt="">
                    <span>{{_i18n('缘分')}}</span>
                </li>
                <li class="f-list" onclick="_index(1)">
                    <img src="../image/tabbar/dongtai_nor.png" alt="">
                    <span>{{_i18n('动态')}}</span>
                </li>
                <li class="f-list" onclick="_index(7)">
                    <img src="../image/tabbar/supei_nor.png" alt="">
                    <span>{{_i18n('速配')}}</span>
                </li>
<!--                <li class="f-list" onclick="_index(10)">-->
<!--                       <img class="supei" src="../image/index_images/supei.png" alt="">-->
<!--                      <span class="su-t">速配</span>-->
<!--                  </li>-->
                <!-- <li class="f-list" onclick="_index(6)">
                    <img src="../image/index_images/button6.png" alt="">
                    <span>直播</span>
                </li> -->
                <li class="f-list" onclick="_index(2)">
                    <img src="../image/tabbar/liaotian_nor.png" alt="">
                    <span>{{_i18n('聊天')}}</span>
                    <span class="num new-hide"></span>
                </li>
                <li class="f-list" onclick="_index(4)">
                    <img src="../image/tabbar/wode_nor.png" alt="">
                    <span>{{_i18n('我')}}</span>
                </li>
            </ul>
        </footer>
    </div>
</body>
<script src="../script/jquery.js"></script>
<script src="../script/api.js"></script>
<script src="../script/ffkj.js"></script>
<script src="../script/group.js"></script>
<script src="../script/map.js"></script>
<script src="../script/vue.js"></script>
<script src="../script/update.js"></script>

<script src="../script/swiper.js"></script>
<script src="../script/index.js"></script>
<script>
    var view = new Vue({
        el: '#view',
        data: {
            ios: 1, // 1上架 0非上架,
            lbList: [],
            act: 4,
            bpTime: 0,
            bapin: {
                content: '',
                time: 0
            }, // 霸屏
            xuni: [],
        },
        methods: {
            // 跳转 查看用户详情
            go_userInfo(id, name, sex) {
                go_userInfo(id, name, sex)
            },
            // 跳转
            _url(param, url) {
                _url(param, url);
            },
            // 返回图片路径
            returnImg(url) {
                return returnImg(url);
            }
        }
    })
    var index_sex = $api.getStorage('sex');
    var map;

    apiready = function() {
        $api.fixStatusBar($api.dom('header'));
        $api.fixTabBar($api.dom('footer'));
        map = new Map();
        view.ios = $api.getStorage('shang');

        _heibai(1)
        keyback();


        changeMsgNum()
        // 监听消息数量
        _listener('msgNum', function(ret) {
            if (ret && ret.value) {
                var result = ret.value;
                changeMsgNum(result)
            }
        })
        getAddress()
        _listener('viewappear', function() {
            getAddress()
        })
        getBapin();
        // 获取首页轮播
        // swiperLoad(function () {
        _getUser(function(ret) {
            setOnline(1);
            if (ret.result.shoushi) {
                changeFrame(4);
                setTimeout(function() {
                    _url({
                        type: 2,
                        animationType: 0
                    }, 'frame4/pwd');
                }, 100)
            } else {
                changeFrame(4);
            }
            if (ret.result.zhaohu == 1 && !view.ios) {
                setTimeout(function() {
                    showDetail('modal/hi_modal')
                }, 1000)
            }

        })
        // })

        setTimeout(function() {
            updateVision()
        }, 2000)

        // setTimeout(function () {
        //     showDetail('modal/index_ad')
        // }, 3000)


        _listener('newmsg', function(ret) {
            showMsgFrm(ret.value.data)
        })
        _listener('Speaker', function(ret) {
            var result = ret.value.result;
            setTVScroll(result);
        })

        getBeauty()
    }

    // 获取排行榜开启状态 0: 该排行榜显示 1隐藏
    //1恩爱(亲密度)|2女神(收到礼物)|3富豪(送出礼物)|4男神(收到礼物)|5家族(威望)|6(魅力值)|8邀请
    function getRankArr() {
        _ajax('api/config/ranking', function(ret, err) {
            if (ret && ret.code == 200) {
                $api.setStorage('rankArr', ret.data);
                _url({}, 'frame0/index_rank_win')
            } else {
                _msg(ret.msg);
            }
        })
    }


</script>

</html>
